load("@rules_go//go:def.bzl", "go_library", "go_test")

go_library(
    name = "cleanup",
    srcs = ["cleanup.go"],
    importpath = "github.com/pachyderm/pachyderm/v2/src/internal/cleanup",
    visibility = ["//src:__subpackages__"],
    deps = [
        "//src/internal/errors",
        "//src/internal/log",
        "@org_uber_go_zap//:zap",
    ],
)

go_test(
    name = "cleanup_test",
    srcs = ["cleanup_test.go"],
    embed = [":cleanup"],
    deps = [
        "//src/internal/cmputil",
        "//src/internal/errors",
        "//src/internal/pctx",
        "//src/internal/require",
        "@com_github_google_go_cmp//cmp",
    ],
)
